const { DBKEY } = require("../config")
const { db, } = require("../utils")
const log = require("../utils/log")
const axios = require('axios')


module.exports =async function request(params) {
   var data = await db.getVal(DBKEY)
   
   var params = Object.assign({
     headers: {
       "X-Auth-Token": data.access_token,
       "Content-Type": "application/x-www-form-urlencoded",
     },
   }, params)

   return axios(params);
}